package com.tuanzi.loan.web.lazy.statistics.login;

import com.tuanzi.loan.business.service.statistics.StatMarketLoginService;
import com.tuanzi.loan.core.lazy.BaseLazyDataModel;
import com.tuanzi.loan.core.util.SpringContextHolder;
import com.tuanzi.loan.core.vo.PageSearcher;
import com.tuanzi.loan.vo.request.statistics.login.StatMarketLoginRequest;
import com.tuanzi.loan.vo.response.statistics.login.StatMarketLoginResponse;
import org.springframework.data.domain.Page;

/**
 * @Author: chenweijun
 * @Date: 2019/3/6 17:26
 * @Description:
 */
public class StatMarketLoginLazyDataModel extends BaseLazyDataModel<StatMarketLoginRequest, StatMarketLoginResponse> {


    private StatMarketLoginService statMarketLoginService = SpringContextHolder.getBean(StatMarketLoginService.class);

    public StatMarketLoginLazyDataModel(StatMarketLoginRequest request) {
        super(request);
    }

    @Override
    protected Page<StatMarketLoginResponse> doLoad(PageSearcher<StatMarketLoginRequest> pageSearcher) {
        return statMarketLoginService.list(pageSearcher);
    }
}
